<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of BaseDAO
 *
 * @author laimis
 */
class BaseDAO {
    private $db;
    public function initDB(){
        define('BASEADDR', 'http://localhost/gallerymodel/');
        define('HOSTNAME', 'localhost');
        define('USERNAME', 'root');
        define('PASSWORD', 'l');
        define('DATABASE', 'gallerymodel');
        $this->db = @mysql_connect(HOSTNAME, USERNAME, PASSWORD) or die('Nepavyko prisijungti prie duomenu bazes');
        @mysql_select_db(DATABASE) or die('Duomenu baze nerasta');
        @mysql_query("set names 'utf8'");
    }
}
?>
